<?php
declare (strict_types = 1);

namespace app\common\system\model;

use think\Model;
use think\model\concern\SoftDelete;

class User extends Model
{
    protected $table = "tk_system_user";
    use SoftDelete;
    protected $defaultSoftDelete = 0;

    public function department()
    {
        return $this->hasMany(UserDepartment::class, 'user_id', 'id');
    }

    public function role()
    {
        return $this->hasMany(UserRole::class, 'user_id', 'id');
    }
}
